0b6db04e4024f137a8316ceec9e7ca8bef636d0a,source/net/yacy/document/parser/html/ContentScraper.java,ContentScraper,scrapeTag0,#Tag#,362
Before Change
final AnchorURL url = absolutePath(src);
if (url != null) {
final int width = Integer.parseInt(tag.opts.getProperty("width", "-1"));
final int height = Integer.parseInt(tag.opts.getProperty("height", "-1"));
final ImageEntry ie = new ImageEntry(url, tag.opts.getProperty("alt", EMPTY_STRING), width, height, -1);
this.images.add(ie);
}
After Change
// use Numberformat.parse to allow parse of "550px"
NumberFormat intnum = NumberFormat.getIntegerInstance ();
final int width = intnum.parse(tag.opts.getProperty("width", "-1")).intValue(); // Integer.parseInt fails on "200px"
final int height = intnum.parse(tag.opts.getProperty("height", "-1")).intValue();
final ImageEntry ie = new ImageEntry(url, tag.opts.getProperty("alt", EMPTY_STRING), width, height, -1);
this.images.add(ie);
}